import http from "../axios";
// 访客管理列表
export const visitorListApi = (data: Base.GeneraDataType = {}): Promise<any> => {
  return http({
    url: "/system/visitor/list",
    method: "post",
    data
  });
};
// 新增访客
export const addVisitorApi = (data: Base.GeneraDataType = {}): Promise<any> => {
  return http({
    url: "/system/visitor/save",
    method: "post",
    data
  });
};
// 编辑访客
export const editVisitorApi = (data: Base.GeneraDataType = {}): Promise<any> => {
  return http({
    url: "/system/visitor/update",
    method: "post",
    data
  });
};
// 签到
export const signInApi = (data: Base.GeneraDataType = {}): Promise<any> => {
  return http({
    url: "/system/visitor/signIn",
    method: "post",
    data
  });
};
// 统计
export const visitorStatisticsApi = (params: Base.GeneraDataType = {}): Promise<any> => {
  return http({
    url: "/system/visitor/getSignStatistics",
    method: "get",
    params
  });
};
// 导入访客
export const importVisitorApi = (data: Base.GeneraDataType = {}): Promise<any> => {
  return http({
    url: "/system/visitor/importData",
    method: "post",
    data,
    headers: {
      "Content-type": "multipart/form-data"
    }
  });
};
